package com.kingdee.eas.hr.quali.impl;

import java.text.SimpleDateFormat;
import java.util.HashMap;
import java.util.Iterator;
import java.util.Map;

import com.kingdee.bos.Context;
import com.kingdee.eas.basedata.person.PersonInfo;
import com.kingdee.eas.framework.CoreBaseInfo;
import com.kingdee.shr.base.syssetting.app.io.fileImport.BaseColumnInfo;
import com.kingdee.shr.base.syssetting.app.io.fileImport.BaseImportService;
import com.kingdee.shr.base.syssetting.app.io.fileImport.BaseRowInfo;
import com.kingdee.shr.base.syssetting.app.io.fileImport.ImportException;
import com.kingdee.shr.base.syssetting.app.io.fileImport.ValueCovertUtils;

public class QualiCommentPlanInportService extends BaseImportService {
	private Map<String, Object> currRowMap;

	@Override
	protected void verifyRow(BaseRowInfo row) throws ImportException {
		this.currRowMap = getRow(row);
		Context ctx = getContext();
		SimpleDateFormat format = new SimpleDateFormat("yyyy-MM-dd");
		String person = currRowMap.get("person").toString();
		String personNumber = currRowMap.get("personNumber").toString();
		String applyQuali = currRowMap.get("applyQuali").toString();
		String standardsNumber = currRowMap.get("standardsNumber").toString();
		
		
		PersonInfo personinfo = null;
	}

	private Map<String, Object> getRow(BaseRowInfo row) {
		Map rowMap = new HashMap();
		Map columnInfoMaps = row.getMapColumnInfo();
		Iterator iterator = columnInfoMaps.entrySet().iterator();
		while (iterator.hasNext()) {
			BaseColumnInfo columnInfo = (BaseColumnInfo) ((Map.Entry) iterator
					.next()).getValue();
			if (columnInfo == null)
				continue;
			String value = row.getValueOfStringByIndex(columnInfo
					.getColumnIndex());
			if (value == null)
				continue;
			String valueName = ValueCovertUtils.getComplexNameOfValue(value);
			rowMap.put(columnInfo.getPropName(), valueName);
		}
		return rowMap;
	}

	@Override
	protected void verifyRowBiz(BaseRowInfo arg0) throws ImportException {
		// TODO Auto-generated method stub
		super.verifyRowBiz(arg0);
	}

	@Override
	protected void submitData(CoreBaseInfo arg0) throws ImportException {
		super.submitData(arg0);
	}

	@Override
	protected void importRow(BaseRowInfo row) throws ImportException {

	}
}
